import { getAction, deleteAction, putAction, postAction, httpAction, downFile } from '@/api/manage'

/*-----------工作小组-----------*/
const serviceName = '/sjsk-crowmanage-service'
const addGroup = (params) => postAction(`${serviceName}/group/addGroup`, params)
const appointDeleteGroup = (params) => postAction(`${serviceName}/group/appointDeleteGroup`, params)
const deleteGroup = (params) => postAction(`${serviceName}/group/deleteGroup`, params)
const pageNewGroup = (params) => postAction(`${serviceName}/group/pageNewGroup`, params)
const pageNewWorkGroup = (params) => postAction(`${serviceName}/group/pageNewWorkGroup`, params)
const viewGroupInfos = (params) => postAction(`${serviceName}/group/viewGroupInfos`, params)
const viewGroupMembers = (params) => postAction(`${serviceName}/group/viewGroupMembers`, params)
const addWorkGroup = (params) => postAction(`${serviceName}/group/addWorkGroup`, params)
const exportGroup = (params) => downFile(`${serviceName}/group/exportGroup`, params, 'post')
const exportWorkGroup = (params) => downFile(`${serviceName}/group/exportWorkGroup`, params, 'post')

export {
  addGroup,
  appointDeleteGroup,
  deleteGroup,
  pageNewGroup,
  pageNewWorkGroup,
  viewGroupInfos,
  viewGroupMembers,
  addWorkGroup,
  exportGroup,
  exportWorkGroup,
}
